package com.huhu.levelloader;

import org.andengine.engine.Engine;
import org.andengine.engine.camera.BoundCamera;
import org.andengine.extension.physics.box2d.PhysicsWorld;
import org.andengine.extension.tmx.TMXTiledMap;
import org.andengine.opengl.vbo.VertexBufferObjectManager;

import com.badlogic.gdx.physics.box2d.ContactListener;
import com.huhu.interfaces.IPlayer;
import com.huhu.manager.ResourcesManager;
import com.huhu.scenes.GameScene;

public abstract class LevelLoader {
	protected Engine engine;
	protected GameScene scene;
	protected BoundCamera camera;
	protected PhysicsWorld physicsWorld;
	protected VertexBufferObjectManager vbom;
	protected ResourcesManager resourcesManager;
	
	public LevelLoader(Engine engine, GameScene scene, BoundCamera camera, PhysicsWorld physicsWorld, VertexBufferObjectManager vbom){
		this.engine = engine;
		this.scene = scene;
		this.camera = camera;
		this.physicsWorld = physicsWorld;
		this.vbom = vbom;
		this.resourcesManager = ResourcesManager.getInstance();
		
		this.physicsWorld.setContactListener(contactListener());
		createHUD();
	}
	protected abstract void createHUD();
	public abstract IPlayer createPlatform(TMXTiledMap mTMXTiledMap);
	protected abstract ContactListener contactListener();
}
